//
//  UserCenterCell.m
//  YuBao
//
//  Created by hok on 10/11/15.
//  Copyright © 2015 hok. All rights reserved.
//

#import "UserCenterCell.h"

#define Split_Section_Horizontal_Width 12.

@implementation UserCenterCell

+ (UINib *)nib
{
    return [UINib nibWithNibName:@"UserCenterCell" bundle:nil];
}
- (void)awakeFromNib {
    // Initialization code
    
   /* UIView *backView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, self.bounds.size.width,  self.bounds.size.height)];
    //backView.alpha = 0.3;
    backView.backgroundColor = UIColorFromRGBA(kTableViewSplitLineColor, 0.3);

    self.selectedBackgroundView = backView;*/
    
    
    //self.title.font = [UIFont fontWithName:@"PingFangSC-light" size:ScaleForScreen(14)];
}

- (void)drawRect:(CGRect)rect {
    // Drawing code

    UIBezierPath *path = [UIBezierPath bezierPath];
    [path moveToPoint:CGPointMake(0 , kUserCenterCellHeight - 1)];
    [path addLineToPoint:CGPointMake([UIScreen mainScreen].bounds.size.width, kUserCenterCellHeight - 1 )];
    // 将path绘制出来
    [UIColorFromRGBA(kTableViewSplitLineColor, 1.0) setStroke];
    [path stroke];

    
//    if (self.indexPath.row ==2 || self.indexPath.row ==5 || self.indexPath.row == 7) {
//     /*   UIBezierPath *p = [UIBezierPath bezierPath];
//        [p setLineWidth:Split_Section_Horizontal_Width];
//        
//        
//        [p moveToPoint:CGPointMake(0 , self.bounds.size.height - Split_Section_Horizontal_Width/2 - 2.0)];
//        [p addLineToPoint:CGPointMake(self.bounds.size.width, self.bounds.size.height - Split_Section_Horizontal_Width/2 - 2.0 )];
//        [UIColorFromRGBA(kTableViewSplitLineColor,1.0) setStroke];
//        [p stroke];*/
//    }else{
//        UIBezierPath *path = [UIBezierPath bezierPath];
//        [path moveToPoint:CGPointMake(0 , self.bounds.size.height - 1)];
//        [path addLineToPoint:CGPointMake([UIScreen mainScreen].bounds.size.width, self.bounds.size.height - 1 )];
//        // 将path绘制出来
//        [UIColorFromRGBA(kTableViewSplitLineColor,1.0) setStroke];
//        [path stroke];
//    }
   

}


- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
    
    //[self setNeedsLayout];

    // Configure the view for the selected state
}

@end
